package com.example.entity;

import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import lombok.Data;

import java.util.Date;
import java.util.List;

@TableName("t_product_health")
@Data
public class ProductHealth {
    private Integer id;//编号
    private String healthName;//健康套餐名称
    private String description;//描述
    private String image = "default.jpg";//图片

//    private boolean abc = false;
    private Boolean isHot = false;//是否热卖
    private Double discount;//折扣
    @JsonSerialize(using = CustomDateTimeSerializer.class)
    @JsonDeserialize(using = CustomDateTimeDeserializer.class)
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private Date hotDateTime; // 设置热门推荐日期时间
    @TableField(select = false)
    private List<ProductHealthItem> productHealthItems; // 健康套餐包含的产品项
    @TableField(select = false)
    private List<ProductSwiperImage> productSwiperImageList;

}
